Skip to main content

speechGetVoices

Type

handler

Summary

Get an array of system voice information

Syntax

speechGetVoices()

Description

Use speechGetVoices to obtain details of the system voices. Each key in the returned array is a voice identifier that can be used with the speechSetVoice command. Each element has a name and a locale key:

  • name: A name for the voice
  • locale: A locale for the voice
note

Getting voices is supported on Android 6+. On earlier versions this handler returns nothing.

Examples

    local tVoices
put speechGetVoices() into tVoices

local tEnglishVoiceNames
repeat for each element tVoice in tVoices
if tVoice["locale"] begins with "en" then
put tVoice["name"] & return after tEnglishVoiceNames
end if
end repeat

Compatibility and Support

OS

mac

ios

android

Platforms

desktop

mobile